<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>test3</title>
	<script type="text/javascript">
		var s = "gal阿打发kfgafgaji阿发oagfs噶放个ujga噶费fauga";
		var obj = {};
		for(var i = 0; i < s.length; i++){	
			var c = s.charAt(i);
			if(obj[c] && typeof obj[c] == "number"){
				obj[c]++;
			}else{
				obj[c]=1;
			}
		}
		document.write(s + "<br>");
		for(var p in obj){
			if(typeof obj[p] == "number"){
				document.write(p + ":" + obj[p] + "<br>");
			}
		}
	</script>
</head>
<body>
</body>
</html>